Different strategies may be employed in a digital communication network to control the flow of digital data traffic into, through and from different areas of the network. Broadly, traffic control of one or more traffic flows can be divided into two categories: i) “traffic shaping”; and ii) “traffic policing”. Traffic policing and shaping are complementary operations to one another and are commonly used in combination within digital communication networks and sub-networks.
Traffic delivery and control is done according to an agreed upon Service Level Agreement (SLA) that is specified for a particular traffic flow or set of traffic flows. A typical SLA will specify such things as a maximum data rate, allowable burst tolerance and one or more thresholds associated with each. Shaping and policing traffic controls regulate and enforce the rate of data transfer at a given point or points in the digital communication network.
Each traffic flow may be a data stream from a single user or multiple data streams from multiple users that have been multiplexed together into a single traffic flow. A traffic flow representing a single data stream can be considered a “micro-flow” and a traffic flow made-up of multiple data streams can be considered a “macro-flow”. In this light it can be recognized that traffic control can be enforced either on a single micro-flow, a set of micro-flows or an entire macro-flow. However, thus far it has been difficult to fairly enforce traffic control at both the micro-flow and macro-flow levels simultaneously.
Traffic shaping involves the redistribution of the contents (e.g. packets or the like) of a traffic flow in the time domain so that the traffic flow conforms to an agreed upon SLA. That is, traffic shaping forces the data rate of a particular traffic flow down to a predetermined data rate when the data rate of the traffic flow is too high. The data rate of a traffic flow can be lowered by buffering and queuing packets of the traffic flow. Despite being able to slow down a traffic flow, a traffic shaper does not have the ability to increase the rate (speed) of traffic flows that have respective data rates below the data rate(s) permitted under the SLA. Shaping is typically done by the source of the traffic.
Traffic policing involves the enforcement of one or more traffic parameters which might be specified in a SLA. For example, a traffic policer determines whether or not a traffic flow has exceeded its respective maximum data rate(s) and/or burst tolerance(s) permitted under its SLA. If in violation, the traffic policer may either mark or discard packets of the traffic flow that are considered to be violating the SLA specified for the traffic flow. Marking allows the violating portions of the traffic flow, now being marked traffic, to continue on towards its destination. However, subsequent network elements will recognize marked traffic and will be more likely to discard it in the event of congestion.
Conventional traffic policers are usually very restrictive while conventional traffic shapers add delays to traffic flows. If a traffic flow is carrying real-time data, such as voice communications, then dropped packets from the traffic flow or delays caused by redistribution will lower the Quality of Service (QoS) to low levels where real-time communications are poor and unreliable. It is also generally true that the restrictive operation of conventional traffic policers lowers the effective rate and efficiency with which a traffic channel medium, such as an optical fiber, can be used.
For example, referring to FIG. 1 shown is a conventional Dual-Leaky Bucket Policer 100 commonly used to control Frame Relay (FR) type traffic flows. In a RF system digital data is organized into frames that are transmitted through links on a communication network. Typically a particular frame will have one of two Discard Eligibility (DE) values “1” or “0” where “1” indicates a high probability of discard and “0” indicates a low probability of discard. Accordingly, frames marked with a DE of “1” are more likely to be discarded by a traffic policer than frames marked with a DE of “0”.
The Dual-leaky Bucket Policer 100 has a Discard Eligibility Switch (DES) 102 and first and second policers 104 and 106. The DES 102 is coupled to accept frames and is further coupled to deliver frames to the first and second policers 104 and 106. Each policer 104 and 106 enforces a specified maximum data rate and burst tolerance. Specifically, the first policer 104 enforces a maximum data rate Rc and a maximum burst tolerance of Bc. The second policer 106 enforces a maximum data rate of Re-Rc, where Re>Rc, and a maximum burst tolerance of Be-Bc, where Be>Bc. The data Rc can be considered the committed (or guaranteed) data rate permitted through the Dual-Leaky Bucket Policer 100, whereas the data rate Re can be considered the excess data rate permitted through the Dual-Leaky Bucket Policer 100. Similarly, the burst tolerance Bc is the committed (or guaranteed) burst tolerance permitted through the Dual-Leaky Bucket Policer 100, whereas the burst tolerance Be is the excess data rate permitted through the Dual-Leaky Bucket Policer 100.
The operation of the Dual-Leaky Bucket Policer 100 is as follows. The DES 100 receives a sequence of frames, each frame having either a DE of “1” or “0”. The received sequence of frames may be continuous or bursty. The DES 102 diverts frames having a DE of “0” to the first policer 104 and diverts frames having a DE of “1” to the second policer 106.
In the first policer 104, if the frames received have a data rate less than or equal to the maximum data rate Rc (i.e. the committed rate) then the frames flow through the policer 104 without modification. If the frames received have a data rate greater than Rc but have not exceeded its burst tolerance Bc (i.e. the committed burst size) the frames are still considered to be conforming with the limitations of policer 104 and are able to flow through 104 without modification. However, if the frames received exceed both Rc and Bc then their respective DE's are changed from “0”0 to “1” and type are diverted to the second policer 106 as indicated by 103.
The operation of the first policer 104 is as follows. A credit count is maintained for the bucket. The credit count is a representation of how many traffic units (these cold be packets, bytes or any other appropriate unit) have been received which are in excess of the rate Rc. Each policing interval, the credit count is decremented by a number of credits allowed per policing interval by the rate Rc. Therefore, if the policing interval is Tp seconds, and the rate Rc is in units per second, then the number of credits which would be decremented would equal Tp×Rc. Next, as each packet arrives for policing, if the current credit count exceeds the burst tolerance, then the traffic is marked as DE “1” and included in flow 103 which is passed to the input of the second policer 106. If the current credit count does not exceed the burst tolerance, the packet is allowed to pass. At that time, the credit count is incremented by the number of traffic units of the packet.
The second policer 106 works in a manner similar to the first policer 104. However, the input to the policer 106 is the combination of received frames (directly from the DES 102) having a DE of “1” and the overflow (non-conforming traffic) from the first policer 104 having been marked to have a DE of “1”.
A problem with this design is that the second policer 106 does not distinguish between the frames coming from the first policer 104 or the DES 102 when discarding. If the DE “0” traffic is less than what is permitted by the first policer 104 there is no way for the DE “1” marked frames from the DES 102 to take advantage of the unused bandwidth controlled by the first policer 104.